Colin Walters [Fri, 5 Jan 2018 21:02:58 +0000 (16:02 -0500)]
rofiles: Fix --copyup when creating a new file
This tripped up the `docbook-dtds` `%post` in my experiments
with doing rpm-ostree for buildroots.
I cloned and built [xfstests](https://git.kernel.org/pub/scm/fs/xfs/xfstests-dev.git)
but haven't yet investigated actually running it.
In the meantime let's do the obvious fix here; we need to distinguish
between "copyup enabled" and "actually did a copyup" in the open path
at least, since if we didn't do a copyup we don't need to re-open.
Colin Walters [Thu, 14 Dec 2017 16:05:00 +0000 (11:05 -0500)]
rofiles: Add --copyup option
Sadly https://sourceware.org/bugzilla/show_bug.cgi?id=22089 is I think going to
actually force us to cave here. Even if we got the glibc patch in today, we need
to support the RHEL glibc. See also discussion about fish as part of the general
Fedora tracker.
This is basically needed to unblock rpm-ostree unified core š:
https://github.com/projectatomic/rpm-ostree/issues/729
Colin Walters [Tue, 2 Jan 2018 14:54:52 +0000 (09:54 -0500)]
build-sys: Link with -ldl for rust build
I didn't dive into this too much, it looks like something in rust changed that
broke our build. Probably libstd gained a dependency on `-ldl` or so, and that's
handled by cargo? Anyways linking against it isn't going to hurt.
Simon McVittie [Sun, 10 Dec 2017 19:39:38 +0000 (19:39 +0000)]
tests: Don't assume uid == primary gid
Nothing guarantees that each user has a group containing only
themselves. Even if they do, nothing guarantees that its group ID
equals the user ID, particularly if another user earlier in the same
range was created without a corresponding group or vice versa.
Signed-off-by: Simon McVittie <smcv@collabora.com> Closes: #1390
Approved by: cgwalters
Colin Walters [Thu, 21 Dec 2017 21:31:18 +0000 (22:31 +0100)]
ci: Make rust build nonblocking for now
Will debug at some point but for now let's
unblock other things.
```
/usr/bin/ld: /var/tmp/checkout/target/release/libbupsplit_rs.a(bupsplit_rs-db7d02fa07221ce3.bupsplit_rs0.rust-cgu.o): undefined reference to symbol 'dladdr@@GLIBC_2.2.5'
```
Colin Walters [Fri, 15 Dec 2017 14:20:58 +0000 (09:20 -0500)]
build-sys: Use -fno-strict-aliasing by default
See discussion in https://bugzilla.gnome.org/show_bug.cgi?id=791622
This is what e.g. systemd, the Linux kernel, and lots of other projects do. It's
astonishingly hard to reliably get right; the optimization IMO only really
matters for truly high performance inner loops, but if you're doing
that kind of stuff today you're probably doing it on a GPU anyways.
Colin Walters [Thu, 14 Dec 2017 17:54:24 +0000 (12:54 -0500)]
bin/commit: Support creating "unbound" commits
We had this basically forced on in the CLI; down the line I'd really like to
make this an API option to commit or so, but given that we found a use case in
the rpm-ostree test suite for "unbound" commits, let's support creating them
from the cmdline.
Colin Walters [Thu, 14 Dec 2017 17:09:28 +0000 (12:09 -0500)]
lib/core: Optimize breaking hardlinks for regfiles
It'd all be really nice if there was some sort of `O_TMPFILE` for symlinks, but
anyways the way we were doing a generic "make temp file than rename" actually
defeats some of the point of `O_TMPFILE`. It's now fully safe to do "copy to
self", so let's do that for regfiles.
Colin Walters [Thu, 14 Dec 2017 16:10:35 +0000 (11:10 -0500)]
lib/core: Add a "break hardlink" API
This imports the code from rpm-ostree:
https://github.com/projectatomic/rpm-ostree/blob/9ff9f6c997d914cb7d97d6b59d8045ba64a1882c/src/libpriv/rpmostree-util.c#L742
I plan to use this for rofiles-fuse to implement
copyup: https://github.com/ostreedev/ostree/issues/1377
But it's just obviously generally useful for projects using
libostree I think.
Colin Walters [Thu, 14 Dec 2017 17:36:48 +0000 (12:36 -0500)]
bin/fsck: Make ref binding verification optional
Today the rpm-ostree test suite uses `refs --create` to save
commits. I think this is a legitimate use case, and other
people may be doing something similar.
On the other hand, I think we should probably be changing the rpm-ostree test
suite to create "unbound" commits. But let's be maximially compatible here since
we hit a real-world case where something needed to change.
Colin Walters [Thu, 14 Dec 2017 14:48:26 +0000 (09:48 -0500)]
lib/repo: Add an API to mark a commit as partial
For the [rpm-ostree jigdo ā²š¦](https://github.com/projectatomic/rpm-ostree/issues/1081) work.
We're basically doing "pull" via a non-libostree mechanism, and this
should be fully supported. As I mentioned earlier we should try to
have `ostree-repo-pull.c` only use public APIs; this gets us closer
to that.
Colin Walters [Wed, 13 Dec 2017 19:27:19 +0000 (14:27 -0500)]
lib/repo: Disable locking by default, add locking=true boolean
I want some time to play with this more with different callers and work through
test scenarios. Let's disable the locking by default for now, but make it easy
to enable.
Philip Withnall [Mon, 20 Nov 2017 14:48:04 +0000 (14:48 +0000)]
ostree/commit: Allow --orphan and --bind-ref to be specified together
Typically youād use --branch and --bind-ref together to add additional
bindings as well as creating a main --branch for the commit. However,
you might also want to occasionally use --orphan --bind-ref to create a
commit with bindings for one or more refs, but not actually create any
of those refs pointing to the commit (you might create them as a later
step).
Signed-off-by: Philip Withnall <withnall@endlessm.com> Closes: #1347
Approved by: cgwalters
Philip Withnall [Mon, 20 Nov 2017 13:16:35 +0000 (13:16 +0000)]
ostree/fsck: Add --verify-back-refs option
This new option verifies that the refs listed in the ref-bindings for
each commit all point to that commit (i.e. there arenāt multiple commits
listing the same ref in their ref-bindings, and there arenāt any commits
with non-empty ref-bindings which arenāt pointed at by a ref).
This is useful when generating a new repository from scratch, but not
useful when adding new commits to an existing repository (since the old
commits will still, correctly, have ref-bindings from when the refs
pointed at them). Thatās why it has to be enabled explicitly using
--verify-back-refs, rather than being on by default.
Signed-off-by: Philip Withnall <withnall@endlessm.com> Closes: #1347
Approved by: cgwalters
Philip Withnall [Wed, 13 Dec 2017 12:51:59 +0000 (12:51 +0000)]
ostree/fsck: Handle refspecs from ostree_repo_list_refs()
It seems ostree_repo_list_refs() can return refspecs as hash table keys,
as well as just ref names. Handle that by parsing them before trying to
use them as ref names.
Signed-off-by: Philip Withnall <withnall@endlessm.com> Closes: #1347
Approved by: cgwalters
Philip Withnall [Mon, 20 Nov 2017 12:51:28 +0000 (12:51 +0000)]
ostree/fsck: Verify commit bindings for each ref
Since an OSTree client will refuse to pull from a remote which it has
locally configured with a collection ID, if the commit on that remote
has incorrect or missing bindings, weād better verify them as part of
fsck.
Signed-off-by: Philip Withnall <withnall@endlessm.com> Closes: #1347
Approved by: cgwalters
Colin Walters [Fri, 8 Dec 2017 18:55:39 +0000 (13:55 -0500)]
lib/commit: Use more direct path for regfile commits
In the non-`CONSUME` path for regfiles (which happens currently for
`bare-user`), we go to a lot of contortions to make an "object stream",
only to immediately parse it again.
Fixing this will also enable the `G_IS_FILE_DESCRIPTOR_BASED()` fast path in
commit, since the input stream will actually reference the file descriptor and
not be an `_OstreeChainInputStream`.
There's a slight concern here in that we're no longer checksumming *literally*
the object stream passed in for the stream case, but I mention in the comment,
the data should be the same, and if it's not somehow we're not adding risk,
since the checksum is still covering the data we actually care about.
Prep for further changes to break up the `write_content_object()` path into
separate paths for archive, as well as regfile vs symlink in non-archive.
Colin Walters [Tue, 5 Dec 2017 19:27:15 +0000 (14:27 -0500)]
Add public API for fsck, use it before loading metadata
A while ago I did `truncate -s 0 /path/to/repo/00/123.commit`, and expected a
checksum error, but I actually got a validation error due to us loading the
commit into a variant and trying to parse out the parent checksum, etc.
I first started by changing the `load_and_fsck_one_object()` function to
checksum before loading, but the problem is that we do a traverse of all objects
first. Fixing this is going to require an `OSTREE_REPO_COMMIT_TRAVER_FLAG_FSCK`
or something.
In the meantime at least though, let's add a public API to fsck a single object
which *does* checksum cleanly before parsing the object, and change the `fsck`
command to use it.
We then change the fsck binary to do this while iterating over the refs
and finding the commit object. This way we'll at least get a checksum
first for commit objects, even if not dirtree/dirmeta.
Matthew Leeds [Tue, 5 Dec 2017 20:57:46 +0000 (12:57 -0800)]
lib/repo: Properly list remotes of parent repos
This commit fixes an infinite loop that happens if you try to list the
remotes of a repo that has a parent repo set. It also adds a unit test
to ensure the right behavior, which is that both the child remotes and
parent remotes are listed.
Colin Walters [Tue, 5 Dec 2017 21:33:31 +0000 (16:33 -0500)]
lib/commit: Refactor file commits to separate subdir from content
One major thing we can do to speed up local commits is multithreading. In
preparation for that, split up the recursion function so that the subdirectory
case is separate from the content (regfile/symlink) case. Then for non-subdirs,
we can easily peel off worker threads and gather the final checksums and update
the mtree from the main thread.
The diff here looks large but it's pretty straightforward; amazingly this change
compiled the very first time I tried it!
Colin Walters [Sat, 14 Oct 2017 00:50:28 +0000 (19:50 -0500)]
tests: Test concurrent operations
Test that concurrent commits and prunes can succeed. Mostly this is a
check that the new locking works correctly and the concurrent processes
will properly wait until they've acquired the appropriate repository
lock.
Dan Nicholson [Fri, 6 Oct 2017 11:04:22 +0000 (11:04 +0000)]
lib/prune: Take exclusive repository lock
Add exclusive repository locking to all the pruning entry points. This
ensures that objects and deltas will not be removed while another
process is writing to the repository.
Dan Nicholson [Fri, 13 Oct 2017 19:31:35 +0000 (19:31 +0000)]
lib/repo: Add locking auto cleanup handler
Define an auto cleanup handler for use with repo locking. This is based
on the existing auto transaction cleanup. A wrapper for
ostree_repo_lock_push() is added with it. The intended usage is like so:
Dan Nicholson [Thu, 5 Oct 2017 20:25:11 +0000 (15:25 -0500)]
lib/repo: Add repo locking mechanism
Currently ostree has no method of guarding against concurrent pruning.
When there are multiple repo writers, it's possible to have a pull or
commit race against a prune and end up with missing objects.
This adds a file based repo locking mechanism. The intention is to take
a shared lock when writing objects and an exclusive lock when deleting
them. In order to make use of the locking throughout the library in a
fine grained fashion, the lock acts recursively with a stack of lock
states. If the lock becomes exclusive, it will stay in that state until
the stack is unwound past the initial exclusive push. The file locking
is similar to GLnxLockFile in that it uses open file descriptor locks
but falls back to flock when needed.
The lock also attempts to be thread safe by storing the lock state in
thread local storage with GPrivate. This means that each thread will
have an independent lock for each repository it opens. There are some
drawbacks to that, but it seemed impossible to manage the lock state
coherently in the face of multithreaded access.
The API is a push/pop interface in accordance with the recursive nature
of the locking. The push interface uses an enum that's translated to
LOCK_SH or LOCK_EX as needed. Both interfaces use an internal timeout
field to decide whether to manage the lock in a blocking or non-blocking
fashion. The intention is to allow ostree applications as well as
administrators to control this timeout. For now, the default is a 30
second timeout.
Note that the timeout is handled synchronously in thread since the lock
is maintained in thread local storage. I.e., the thread that acquires
the lock needs to be the same thread that runs the operation. There may
be a way to offer an asynchronous version, but it's not clear exactly
how that would work since it would likely involve a separate thread that
invokes a callback when the locking operation completes.
Colin Walters [Tue, 28 Nov 2017 17:02:03 +0000 (12:02 -0500)]
lib/repo: Add some error prefixing in commit, repo create
I was getting a bare `error: Creating temp file: No such file or directory` when
debugging `test-concurrency.py`; with this I get
`error: Writing content object: Creating temp file: No such file or directory`
which helps me pin it down.
Colin Walters [Fri, 1 Dec 2017 20:18:37 +0000 (15:18 -0500)]
lib/repo: Add MT support for transaction_set_ref(), clarify MT rules
For rpm-ostree I'd like to do importing in parallel with threads; the code is
*almost* ready for that except today it calls
`ostree_repo_transaction_set_ref()`.
Looking at the code, there's really a "transaction" struct here,
not just stats. Let's lift that struct out, and move the refs
into it under the existing lock.
Clarify the documentation around multithreading for various functions.
Colin Walters [Mon, 4 Dec 2017 16:06:58 +0000 (11:06 -0500)]
Release 2017.14
Time to cut a new release, we've got the libcurl cleanup ordering patch which
several people have hit, along with safe early fixes for tmpdir cleanup. Let's
try to land the locking PR early next cycle.
Colin Walters [Fri, 1 Dec 2017 02:43:17 +0000 (21:43 -0500)]
lib/repo: Add a DEVINO_CANONICAL commit modifier flag
I was seeing the `Writing OSTree commit...` phase of rpm-ostree
being very slow lately. This turns out to be more fallout from
https://github.com/ostreedev/ostree/pull/1170
AKA commit: 8fe4536
Loading the xattrs is slow on my system (F27AW, XFS+LVM, NVMe). I haven't fully
traced through why, but AIUI at least on XFS the xattrs are often stored outside
of the inode so it's a little bit like doing an `open()+read()`. Plus there's
the LSM overhead, etc.
The thing is that for rpm-ostree's package layering use case, we
basically always want to treat the on-disk state as canonical. (There's
a subtle case here if one does overrides for something that contains
policy but we'll fix that).
Anyways, so we're in a state now where we do the slow but correct thing by
default, which seems sane. But let's allow the app to opt-in to telling us
"really trust devino". The difference between a `stat()` + hash table lookup
versus the full xattr load on my test case of `rpm-ostree install
./tree-1.7.0-10.fc27.x86_64.rpm` is absolutely dramatic; consistently on the
order of 10s without this support, and <1s with (800ms).
Colin Walters [Tue, 28 Nov 2017 18:03:00 +0000 (13:03 -0500)]
lib/repo: Verify txn stagedir existence after locking
This squashes the last race condition I was actively hitting while running
`test-concurrency.py` in a loop. The race is when process A finds a tmpdir to
reuse, and goes to lock it. Meanwhile process B deletes it and unlocks the lock.
Process A then succeeds at grabbing a lock, but the tmpdir is deleted.
Colin Walters [Tue, 28 Nov 2017 18:01:46 +0000 (13:01 -0500)]
lib/commit: Move txn stagedir deletion/unlock into one place
Previously we'd delete the tmpdir in `rename_pending_loose_objects()`
but do the unlock inside `ostree_repo_commit_transaction()`. Move
them into the same place in the latter function for consistency.
Doesn't fix anything, just a cleanup while reading the code and
working on `test-concurrency.py`.
Dan Nicholson [Sat, 14 Oct 2017 00:52:04 +0000 (19:52 -0500)]
tests: Run python tests with stdout unbuffered
Set the PYTHONUNBUFFERED environment variable during tests so that
python leaves stdout unbuffered. This is helpful when reading logs for
failures since the interleaved stdout and stderr will generally come out
in the right order. It's not perfect since tap-driver.sh does some
special redirection to the log file, but it's an improvement.
Colin Walters [Tue, 28 Nov 2017 14:33:17 +0000 (09:33 -0500)]
lib/commit: Minor refactoring of tmpdir cleanup code
Prep for future work here; let's cleanly separate the path for cleaning up the
txn staging directories from the code that cleans up "other stuff". Currently
only the former case uses the `GLnxLockFile` etc.
Colin Walters [Tue, 28 Nov 2017 11:14:29 +0000 (06:14 -0500)]
lib/commit: Reuse txn dir for tmpfiles
This closes a race condition I was seeing with `test-concurrency.py`. If we
don't have `O_TMPFILE` (or for symlinks) we'll create temporary files;
previously these would be subject to the date-based pruning because we set the
timestamp to 0 for objects.
Having our temporary files also in the txn staging dir ensures that they're
covered by the locking we do for that directory, and it's also generally cleaner
since the lifecycle of all the temporary data for a txn is in one place.
Colin Walters [Fri, 1 Dec 2017 01:43:02 +0000 (20:43 -0500)]
tests/delta-crosscheck: Disable fsync
I was running this recently to test the last delta write changes, and this
helps. We should add an option to repo-init to make this easier at some point.
Colin Walters [Sat, 14 Oct 2017 01:01:20 +0000 (21:01 -0400)]
lib/repo: Add a new private API for bare content writes
This lowers into the commit core what the static delta code
was doing, and improves the API.
The bigger picture issue is that for writing large files, our current "pull" API
where the caller provides a `GInputStream` is very awkward in some scenarios.
For example, we have a whole "libarchive input stream" that is a ~200 line
GObject that boils down to wrapping `archive_read_data()`.
This came more to a head when I was working on rpm-ostree jigdo since I had to
copy that object.
One step we can take after this is to further split `write_content_object()`
into a "write symlink or archive object" versus "write bare content object"
(it already has a mess of conditionals) and teach the latter case to call
this.
The eventual goal here is to make this API public.
Joaquim Rocha [Fri, 24 Nov 2017 13:56:28 +0000 (14:56 +0100)]
lib/remote: Add a method to return the URL
When using dynamic remotes (LAN and USB), we cannot use their name with
the common remote related ops (ostree_repo_remote_...) because ostree
doesn't keep this type of remotes in its internal hash table.
Unfortunately this means that we cannot access the URL of those remotes
either (in order to e.g. set the right URL for those remotes in
Flatpak).
Since the URL is actually stored in a key file that belongs to the
OstreeRemote, then we can simply allow users access to it through a
getter.
So this patch adds a method that allows to return the URL directly from
the OstreeRemote without having to go through the OstreeRepo.
The test-repo-finder-config is also updated by this patch to check if
the URL is correct.
We use utimens instead of utime, thus allowing nanosecond timestamps,
and also fixes a bug where we used to passed UTIME_OMIT to tv_nsec
which made the entire operation a no-op.
In practice anyways I think issues here are better solved on a higher level -
e.g. apps today can use an overall timeout on pulls and if they exceed the limit
set the cancellable.
Jonathan Lebon [Mon, 27 Nov 2017 17:18:56 +0000 (17:18 +0000)]
ci: Make sure we save gtdr test results on failures
If a test fails, we immediately exit and thus never get a chance to
actually upload the test results. Add a trap so that they always
uploaded, even on failure.
Philip Withnall [Tue, 14 Nov 2017 16:13:13 +0000 (16:13 +0000)]
lib/repo: Add (transfer) annotations to various GHashTable arguments
By default, unless itās const, an (out) GHashTable will be assumed to be
(transfer full). That means the binding needs to free all the items in
the hash table, plus the table itself.
However, all the GHashTables we use have free functions set already, so
freeing the hash table will free its items. This results in a
double-free.
Fix that by ensuring we annotate such (out) hash tables as (transfer
container). Also annotate some other hash tables as (transfer none)
where appropriate, for clarity.
This fixes OSTree.Repo.list_collection_refs() in the Python bindings.
Signed-off-by: Philip Withnall <withnall@endlessm.com> Closes: #1341
Approved by: dbnicholson
Dan Nicholson [Thu, 9 Nov 2017 14:43:36 +0000 (14:43 +0000)]
Revert "lib/pull: Skip ostree_repo_resolve_keyring_for_collection for bindings"
This reverts commit 519b30b7e1979fea827ea4fe9b0e9ac4db99d631. Now that
the experimental GIR is being built correctly and OstreeRemote is a real
boxed type, this can be exposed again.
Dan Nicholson [Thu, 9 Nov 2017 13:47:15 +0000 (05:47 -0800)]
lib: Include OstreeRemote and OstreeCollectionRef in GIR
Now that g-ir-scanner is being told about ENABLE_EXPERIMENTAL_API, it
can include these types correctly. Drop the __GI_SCANNER__ guards in the
header files so that all the declarations are found.
After this, you can actually construct the types normally:
>>> OSTree.CollectionRef.new('com.example.Foo', 'bar')
<OSTree.CollectionRef object at 0x7f2bba4c7528 (OstreeCollectionRef at 0x55c033ff2f30)>
Dan Nicholson [Thu, 9 Nov 2017 13:34:16 +0000 (13:34 +0000)]
lib/remote: Export ostree_remote_get_type symbol
Without this, you can't really use OstreeRemote as a GObject, which is a
requirement for bindings.
This was found when attempting to include OstreeRemote in the GIR, and
g-ir-scanner wasn't able to link it's temporary object due to an
"undefined reference to `ostree_remote_get_type'" error.
Colin Walters [Tue, 7 Nov 2017 22:52:12 +0000 (17:52 -0500)]
deltas: Don't try to rollsum/bsdiff .xz files
Fedora switched to 'xz' compress kernel modules, and recently
[RHEL7 did too](https://bugzilla.redhat.com/show_bug.cgi?id=1367496).
This compression defeats bsdiff.
While we have a "rollsum-able" test, we don't have a "bsdiff-able" test as it'd
be very expensive (we'd have to bsdiff, then apply it and compare the result).
Let's do the tactical quick fix here and just not try to delta files ending in
`.xz.`. This avoids us using bsdiff pointlessly for over 4000 files, which is
quite a notable speed increase for generating deltas.
Kalev Lember [Tue, 7 Nov 2017 15:10:45 +0000 (16:10 +0100)]
fetcher/curl: Fix invalid memory access in finalize()
Reorder cleanup functions so that curl_multi_cleanup() runs before
self->sockets is destroyed. This avoids an assert and invalid memory
access in sock_cb where self->sockets is dereferenced during
curl_multi_cleanup().
Colin Walters [Fri, 3 Nov 2017 18:43:00 +0000 (18:43 +0000)]
lib/pull: Avoid error if current with --require-static-deltas
A tricky thing here that caused this to go past a lot of our tests
is that the code was mostly OK if there was an available delta from
an older commit. But this case broke if we e.g. had a new OS
deployment and did a `--require-static-deltas` pull, i.e. the initial
state.
I cleaned up our "find static delta state" function to return an enumeration,
and extended it with an "already have the commit" state. A problem
I then hit is that we've historically fetched detached metadata for
non-delta pulls, even if the commit hasn't changed. I decided not to
do that for `--require-static-deltas` pulls for now; otherwise the
code gets notably more complex.
Colin Walters [Thu, 2 Nov 2017 15:50:12 +0000 (11:50 -0400)]
build: Add -Werror=undef by default, fix fallout
The main thing here is that a ton of stuff has happened in gnulib since we
imported `parse-datetime.y`. I cherry-picked a little bit of it, but that
upstream doesn't seem to build with `-Wundef`, so I just deleted some hunks.
Dan Nicholson [Fri, 3 Nov 2017 20:13:50 +0000 (20:13 +0000)]
tests: Don't symlink rofiles-fuse if it's disabled
Creating the symlink will cause make to try to build rofiles-fuse, which
will fail if it's disabled. Normally I wouldn't disable rofiles-fuse,
but it's triggering a hang in our ARM Xenial builder's kernel in splice.
I'm sure that's fuse's fault, but for now I just need to disable
rofiles-fuse there and found --disable-rofiles-fuse didn't actually
work.
Dan Nicholson [Fri, 3 Nov 2017 16:10:23 +0000 (16:10 +0000)]
lib/pull: Skip ostree_repo_resolve_keyring_for_collection for bindings
Since ostree_remote_get_type is not made available to g-ir-scanner, it
treats OstreeRemote as a bare struct. That's not kosher for bindings and
it issues the following warning:
src/libostree/ostree-repo-pull.c:5560: Warning: OSTree:
ostree_repo_resolve_keyring_for_collection: return value: Invalid
non-constant return of bare structure or union; register as boxed type
or (skip)
Dan Nicholson [Fri, 3 Nov 2017 15:53:19 +0000 (15:53 +0000)]
lib/core: Fix documentation comment in ostree_validate_collection_id
g-ir-scanner was spitting this warning:
src/libostree/ostree-core.c:281: Warning: OSTree:
ostree_validate_collection_id: unknown parameter 'rev' in
documentation comment, should be 'collection_id'
Dan Nicholson [Mon, 16 Oct 2017 15:51:40 +0000 (15:51 +0000)]
build: Define OSTREE_ENABLE_EXPERIMENTAL_API for g-ir-scanner
When compiling libostree, OSTREE_ENABLE_EXPERIMENTAL_API is managed via
config.h. However, g-ir-scanner can't use that since it gets confused
about the namespace of all the random macros. It won't include the
experimental APIs unless the macro is defined through another means.
Without this, none of the experimental APIs were being included in the
gir data.
Dan Nicholson [Fri, 3 Nov 2017 15:47:16 +0000 (15:47 +0000)]
build: Ensure enumtypes.h is built before enumtypes.c
ostree-enumtypes.c includes ostree-enumtypes.h, so make needs to be told
about the dependency. Without it, parallel make could try to build
ostree-enumtypes.c before the header file exists.